//
//  VoiceReadItemListView.h
//  ShowYork
//
//  Created by hxh on 2021/5/17.
//  Copyright © 2021 hxh. All rights reserved.
//

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN


@protocol VoiceReadItemListViewDelegate <NSObject>

@optional

- (void)updateSortType:(NSNumber *)sortType sourceArray:(NSArray *)sourceArray;
- (void)playCurrentVoiceByIndex:(NSInteger)index;
- (void)pauseCurrentVoiceByIndex:(NSInteger)index;
- (void)continueCurrentVoiceByIndex:(NSInteger)index;
- (void)dismissListView;
- (NSNumber *)getNewSortType;

@end

@interface VoiceReadItemListView : UIView

@property (nonatomic,weak)id<VoiceReadItemListViewDelegate>delegate;

- (instancetype)initWithSourceArray:(NSArray *)sourceArray;

- (instancetype)initWithSourceArray:(NSArray *)sourceArray delegate:(id<VoiceReadItemListViewDelegate>)delegate;

- (void)show;

- (void)updateListViewStatus;

- (void)reloadDataWithIndex:(NSInteger)index;

@end

NS_ASSUME_NONNULL_END
